import request from '@/utils/request'

export default {
    getAllChapterVideo(courseId) {
        return request({
            url: `/serviceedu/chapter/getChapterVideo/${courseId}`,
            method: 'get'
        })
    },
    addChapter(eduChapter) {
        return request({
            url: `/serviceedu/chapter/addChapter`,
            method: 'post',
            data: eduChapter
        })
    },
    getChapterInfo(courseId) {
        return request({
            url: `/serviceedu/chapter/getChapterInfo/${courseId}`,
            method: 'get'
        })
    },
    updateChapter(eduChapter) {
        return request({
            url: `/serviceedu/chapter/updateChapter`,
            method: 'post',
            data: eduChapter
        })
    },
    delChapterInfo(courseId) {
        return request({
            url: `/serviceedu/chapter/${courseId}`,
            method: 'delete'
        })
    }
}
